﻿using System;

namespace MathematicallySafe.HeadCounter.Services.Forums
{
    public class phpBBFormatter : IForumFormatter
    {
        public string Bold(string text)
        {
            return "[b]" + text + "[/b]";
        }

        public string Italic(string text)
        {
            return "[i]" + text + "[/i]";
        }

        public string Colour(string text, string colour)
        {
            return string.Format("[color={0}]{1}[/color]", colour, text);
        }

        public string ItemLink(string item, string url)
        {
            return string.Format("[url={0}]{1}[/url]", url, item);
        }

        public string Title(string text)
        {
            return string.Format("[size=150][b]{0}[/b][/size]", text);
        }

        public string EpicTitle(string text)
        {
            return string.Format("[color=#8040BF]{0}[/color]", Title(text));
        }

        public string SubTitle(string text)
        {
            return Italic(text);
        }

        public string Heading(string text)
        {
            return string.Format("{0}[/color]", Bold(text));
        }

        public string SubHeading(string text)
        {
            return Bold(text);
        }
    }
}